package com.carp.shard.plugin.utils;

import java.util.StringTokenizer;

/**
 * 公共工具类
 *
 * @author lile
 * @since 2024/5/31
 */
public class CommonUtils {

    public static String removeBreakingWhitespace(String original) {
        StringTokenizer whitespaceStripper = new StringTokenizer(original);
        StringBuilder builder = new StringBuilder();
        while (whitespaceStripper.hasMoreTokens()) {
            builder.append(whitespaceStripper.nextToken());
            builder.append(" ");
        }
        return builder.toString();
    }

    private CommonUtils() {
    }
}
